<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>我的足迹 - {:config('web.WEB_TIT')}</title>
<meta name="keywords" content="{:config('web.WEB_KEY')}">
<meta name="description" content="{:config('web.WEB_DES')}">
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="apple-mobile-web-app-status-bar-style" content="black"> 
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="format-detection" content="telephone=no">
{include file="index/header"}
<script type="text/javascript">
$(function (){
  var listWidth = $(".list-main li").innerWidth();//取商品列表图片宽
  $(".list-main li img").css('height',listWidth);
})
</script>
<div class="filter">
  <div id="subnav" class="subnav" style="display: block;">
    <div class="subnav-main">
      <ul>
        <li><a href="/">全部</a></li>
        {volist name="CategoryList" id="vo"}
        <li><a href="{:url('cat/'.$vo.id)}" {if condition="$cid eq $vo['id']"}class="active"{/if}>{$vo.name}</a></li>
        {/volist}
      </ul>
    </div>
    <div class="drop-down">
      <a href="javascript:;" onclick="sidenavIn()" class="btn-left"><i class="layui-icon">&#xe61a;</i></a>
    </div> 
  </div>
</div>
<div class="goods-list" style="margin:0 0 60px 0;">
  <div class="layui-main">
    <fieldset><legend><a name="use">浏览记录</a></legend></fieldset>
  </div>
  <ul class="list-main" id="LAY_list">
    {include file="public/goods"} 
    <script type="text/javascript">    
      var listWidth = $(".list-main li").innerWidth()/0.975;
      layui.use('flow', function(){
        var $ = layui.jquery;
        var flow = layui.flow;
        flow.load({
          elem: '#LAY_list'
          ,isLazyimg:true
          ,done: function(page, next){ 
            var lis = [];
            $.get("{:url('AjaxRequest/historyList')}?page="+(page+1), function(res){
              layui.each(res.data, function(index, item){
                lis.push('<li><div class="goods-main"><div class="pic"><a href="'+item.url+'"><img class="lazy" src="__MOBILE__/img/goods-loading.gif" data-original="'+item.pic+'" alt="'+item.title+'" style="height:'+listWidth+'px"></a>'+item.newicon+'</div>'+item.couponAmount+'<h3 class="title"><span class="label">包邮</span>'+item.title+'</h3><div class="original-price"><span class="price"><em>￥</em>'+item.price+'</span><span class="sold">已售 <em>'+item.volume+'</em></span></div><div class="coupon-price"><span class="price"><em>￥</em>'+item.couponPrice+'</span><i class="quan-price"></i><div class="btn-buy"><a href="'+item.jumpurl+'" rel="nofollow"><em class="'+item.icon+'"></em></a></div></div></div></li>');
              });
              next(lis.join(''), page < res.pages);
            });
          }
        });
      });
    </script>  
  </ul>
</div>
{include file="index/footer"}
</body>
</html>
